package com.mallcloud.mall.app.api.entity.vo;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;

@ApiModel(value = "XglQRCodePaymentInfoVO", description = "扫码支付信息查询")
@Data
public class XglQRCodePaymentInfoVO implements Serializable {
	private static final long serialVersionUID = 1L;

	private final static String SUCCESS_CODE = "000000";

	@JsonProperty("result_code")
	@ApiModelProperty("返回请求code")
	private String resultCode;

	@JsonProperty("err_code")
	@ApiModelProperty("返回请求错误code")
	private String errCode;

	@JsonProperty("err_msg")
	@ApiModelProperty("返回请求消息")
	private String errMsg;

	@JsonProperty("mch_id")
	@ApiModelProperty("银行实际的商户号")
	private String mchId;

	@JsonProperty("counter_id")
	@ApiModelProperty("银行实际的柜台号")
	private String counterId;

	@JsonProperty("mch_order_no")
	@ApiModelProperty("商户订单编号")
	private String mchOrderNo;

	@JsonProperty("bank_order_no")
	@ApiModelProperty("银行订单编号")
	private String bankOrderNo;

	@JsonProperty("qr_url")
	@ApiModelProperty("二维码地址")
	private String qrUrl;

	@ApiModelProperty("请求时间")
	private String timestamp;

	@ApiModelProperty("返回签名")
	private String sign;

	public Boolean isSuccess() {
		return SUCCESS_CODE.equals(this.errCode);
	}
}